<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@taglib prefix="g" uri="http://www.trkj.com/crm" %>
<!doctype html>
<html>
<head>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="edge"/>
    <script src="js/saling/fixAccuracyLost.js"></script>
    <link rel="shortcut icon" href="easyui/css/images/favicon.ico"/>
    <title>CRM系统-主页</title>
    <link rel="stylesheet" href="css/flipclock.css">
    <link href="css/CalcSS3.css" rel="stylesheet" type="text/css"/>
    <link href="css/index.css" rel="stylesheet" type="text/css"/>
    <link href="easyui/css/easyui.css" rel="stylesheet" type="text/css">
    <link href="easyui/css/easyui_animation.css" rel="stylesheet"
          type="text/css">
    <link href="easyui/css/easyui_plus.css" rel="stylesheet" type="text/css">
    <link href="easyui/css/insdep_theme_default.css" rel="stylesheet"
          type="text/css">
    <link href="easyui/css/icon.css" rel="stylesheet" type="text/css">
    <link href="easyui/css/font-awesome-4.7.0/css/font-awesome.min.css"
          rel="stylesheet" type="text/css">
    <script type="text/javascript" src="<c:url value="/js/utils/DateFormate.js"/>"></script>

    <!-- 引入公用表格和表单样式 -->
    <link href="css/utils/utilsDatagrid.css" rel="stylesheet"
          type="text/css">
    <link href="css/utils/utilsForm.css" rel="stylesheet" type="text/css">
    <script type="text/javascript" src="js/utils/glass.js"></script>
    <link type="text/css" href="css/utils/glass.css">
    <!-- 引入 ECharts 文件 -->
    <script src="js/echarts.js"></script>
    <!--放入自定义的图表-->
    <script src="js/monitor.js"></script>
    <script type="text/javascript" src="easyui/js/jquery.min.js"></script>
    <script type="text/javascript" src="easyui/js/jquery.easyui.min.js"></script>
    <script type="text/javascript"
            src="easyui/js/jquery.insdep-extend.min.js"></script>
    <script type="text/javascript" src="js/utils/dialog.js"></script>
    <script type="text/javascript" src="js/utils/dialog-hut.js"></script>


    <script type="text/javascript">
        $.extend($.fn.validatebox.defaults.rules, {

            phoneNum: { //验证手机号
                validator: function (value, param) {
                    return /^1[3-8]+\d{9}$/.test(value);
                },
                message: '请输入正确的手机号码。'
            }
        });
        $(function () {
            //随机颜色方法
            function colorChange(d) {
                return "#"
                    + Math.floor(Math.random() * (256 * 256 * 256 - 1))
                        .toString(16);
            }
            //并当选项卡已经存在选中该选项卡时候刷新内容
            $("#home-tabs").tabs({
                onSelect:function () {
                    var currentTab = $('#home-tabs').tabs('getSelected');
                    var url = $(currentTab.panel('options')).attr('href');
                    $('#home-tabs').tabs('update', {
                        tab: currentTab,
                        options: {
                            href: url
                        }
                    });
                    currentTab.panel('refresh');
                }
            });

            //加载echarts组件
            //柱状图
           /*  simpleBar('main'); */
            // renderLegend();
            //饼状图
           /*  renderChartBar01('main1'); */
            //30天日均线流量趋势
            /* renderLayer04Left('main2'); */
            //集群性能
           /*  renderLayer04Right('main3'); */
            
            var comboboxVal = $('#groupClientWhere').combobox('getValue');
            $.get("client-group",{factor:comboboxVal},function(e){
            	var factor=new Array();
            	var count=new Array();
            	for (var i = 0; i < e.length; i++) {
					factor[i] = e[i].factor;
					count[i] = e[i].count;
				}
            	simpleBar('main',factor,count); 
            	//饼状图
            	var jsonstr="[";
            	for (var i = 0; i < e.length; i++) {
            		jsonstr+='{"value":"'+e[i].count+'","name":"'+e[i].factor+'"},';
            	}
            	jsonstr=jsonstr.substring(0,jsonstr.length-1);
            	jsonstr+="]";
                renderChartBar01('main1',jsonstr);
                //30天日均线流量趋势
                renderLayer04Left('main2',factor,count);
                renderLayer04Right('main3',factor,count);
            });
            
            
            
            $('#groupClientWhere').combobox({
            	onChange:function(){
            		/* $('#main').empty();
            		$('#main1').empty();
            		$('#main2').empty() */;
            		simpleBar('main',null,null); 
            		renderChartBar01('main1',null);
            		renderLayer04Left('main2',null,null); 
                    renderLayer04Right('main3',null,null);
            		var val = $('#groupClientWhere').combobox('getValue');
            		 $.get("client-group",{factor:val},function(e){
                     	var factor=new Array();
                     	var count=new Array();
                     	for (var i = 0; i < e.length; i++) {
         					factor[i] = e[i].factor;
         					count[i] = e[i].count;
         				}
                     	simpleBar('main',factor,count); 
                     	//饼状图
                     	var jsonstr="[";
                     	for (var i = 0; i < e.length; i++) {
                     		jsonstr+='{"value":"'+e[i].count+'","name":"'+e[i].factor+'"},';
                     	}
                     	jsonstr=jsonstr.substring(0,jsonstr.length-1);
                     	jsonstr+="]";
                         renderChartBar01('main1',jsonstr);
                         //30天日均线流量趋势
                         renderLayer04Left('main2',factor,count);
                         renderLayer04Right('main3',factor,count);
                     });
            	}
            });
            
            /*
               修改图片并显示或隐藏后面的搜索框
             */
            var s = true;
            var o = null;//保存上次的sid
            $("#searchIcon").click(
                function () {
                    var sid = "search" + new Date().getTime();

                    if (s == true) {
                        $("#change_icon").removeClass("fa-search");
                        $("#change_icon").addClass("fa-times");
                        //通过js创建一个搜索框
                        o = sid;
                        $("<input/>").appendTo(".left").addClass(
                            "easyui-searchbox").addClass(
                            "theme-navigate-search").attr("id", o).css(
                            "width", "450px").searchbox({
                            prompt: "输入搜索的关键词..",
                            menu: "#mm"
                        });
                        // $("<div>").appendTo(".left").addClass("theme-navigate-menu-panel").attr("id","mm");
                        // $("<div>").appendTo("#mm").attr("datap-options","name:'all'").html("全部内容");
                        // $("<div>").appendTo("#mm").attr("datap-options","name:'all'").html("客户");
                        // $("<div>").appendTo("#mm").attr("datap-options","name:'all'").html("联系人");
                        /* $("#top_searchbox").searchbox({prompt:"输入搜索的关键词..",menu:"#mm"});*/
                        s = false;
                        return true;
                    }
                    if (s == false) {
                        $("#change_icon").removeClass("fa-times");
                        $("#change_icon").addClass("fa-search");
                        $("#" + o).searchbox("destroy");
                        s = true;
                        return true;
                    }

                });
            //删除所有选项卡，点击x执行
            $("#close-all").linkbutton({
                onClick: function () {
                    var tabs = $("#home-tabs").tabs("tabs");
                    for (var i = tabs.length - 1; i > 0; i--) {
                        $("#home-tabs").tabs("close", i);
                    }
                }
            });
            //删除当前的选项卡，点击-执行
            $("#close-now").linkbutton({
                onClick: function () {
                    var tab = $("#home-tabs").tabs("getSelected");
                    var index = $("#home-tabs").tabs("getTabIndex", tab);
                    if (index != 0) {
                        $("#home-tabs").tabs("close", index);
                    } else {
                        $.messager.alert("警告", "主页不可以关闭！");
                    }

                }
            });
            //绑定按钮点击事件，打开选项卡和页面
            $(".left-l-btn").linkbutton({
                onClick: function () {
                    var options = $(this).linkbutton("options");
                    var text = options.text;
                    var link = options.link;
                    addTab(text, link);
                }
            });
            //添加选项卡方法
            var addTab = function (text, link) {
                //判断是否存在该选项卡，如果存在，则激活，不存在则创建
                if ($("#home-tabs").tabs("exists", text)) {
                    //存在,激活该选项卡
                    $("#home-tabs").tabs("select", text);
                } else {
                    //不存在，创建
                    $("#home-tabs").tabs("add", {
                        title: text,
                        href: link,
                        closable: true
                    });
                }
            }
            //更换换肤
            $(".skin").linkbutton({
                onClick: function () {
                    //执行换肤操作
                    var color = colorChange();
                    $(".theme-header-layout").css("background-color", color);
                    $(".theme-left-layout").css("background-color", color);
                }
            });
            //联系我们
            $("#link-us")
                .linkbutton(
                    {
                        onClick: function () {
                            $.messager
                                .alert(
                                    "联系我们",
                                    "<h4>我们的邮箱是：<a href='https://mail.qq.com/' style='color:red;'>hutian@qq.com</a></h4>")
                        }
                    });
            //参与改进
            $("#prevent-us")
                .linkbutton(
                    {
                        onClick: function () {
                            $.messager
                                .alert("参与改进计划",
                                    "<h3 style='color：red;'>有建议请联系我们，万分感谢您的宝贵建议！</h3>");
                        }
                    });
            //检测更新
            $("#update-us")
                .linkbutton(
                    {
                        onClick: function () {
                            $.messager
                                .alert("检测更新",
                                    "<h4>当前版本：1.0 Beta</h4><br><h4 style='color:red;'>暂无更新版本！</h4>");
                        }
                    });
            //关于
            $("#about-us")
                .linkbutton(
                    {
                        onClick: function () {
                            $.messager
                                .show({
                                    title: '版权信息',
                                    msg: "<div style='text-align: center; vertical-align: center;margin-top: 40px;'><b style='font-size:18px;'>版权归<a href='https://www.baidu.com' style='color:red;'>HUTechnology</a>所有</b></div>",
                                    showType: 'show',
                                    timeout: 3000,
                                    width: 400,
                                    height: 200,
                                    showSpeed: 0,
                                    style: {}
                                });
                        }
                    });
            //打开计算器
           /*  $("#center-l-btn-1").linkbutton({
                onClick: function () {
                    //创建窗体
                    $("<div>").attr("id", "calculator").window({
                        width: 600,
                        height: 600,
                        closed: true,
                        modal: false,
                        title: '计算器',
                        href: 'Calculator',
                        onClose: function () {
                            $(this).window("destory");
                        }

                    });
                    //打开窗口
                    $("#calculator").window("open");
                }
            }); */

            $("#yk-cancel-zhuxiao").linkbutton({
                onClick: function () {
                    $("#yk-cancel-user").dialog("open");
                }
            });

            $("#yk-cancel-user-btn-close").linkbutton({
                onClick: function () {
                    $("#yk-cancel-user").dialog("close");
                }
            });

            $("#yk-cancel-user-btn-ave").linkbutton({
                onClick: function () {
                    $.get("cancel-Login", function (r) {
                        if (r.success) {
                            location = "tologin";
                        } else {
                            $.messager.alert("提示", r.message);
                        }
                    });
                }
            });
            $('.yk-img').each(function () {
                if ($(this).attr('src').length < 1) {
                    $(this).attr('src', 'easyui/css/images/portrait86x86.png')
                }
            });

        });
    </script>
    <style type="text/css">
        .by {
            padding: 10px;
        }

        .line {
            margin-top: 10px;
        }

        .lineself {
            margin-left: 300px;
            margin-top: 30px;
        }

        .lineselfs {
            margin-left: 450px;
            margin-top: 30px;
        }

        .left-l-btn {
            margin: 0px;
            padding: 0px;
            color: white;
        }

        .left-l-btn:hover {
            border: 0px;
            color: gold;
            background-color: transparent;
        }

        .top-l-btn {
            border: 0px;
            margin: 0px;
        }

        #center-l-btn-1:hover {
            background-color: gold;
        }

        #center-l-btn-1:active {
            background-color: powderblue;
        }

        .your-clock {
            padding: 0px;
            margin: 0px;
            clear: both;
            width: 460px;
        }
    </style>
</head>

<body>
<div id="master-layout">
    <div
            data-options="region:'north',border:false,bodyCls:'theme-header-layout'">
        <div class="theme-navigate">
            <div class="left">
                <a id="searchIcon" class="easyui-linkbutton"><i
                        id="change_icon" class="fa fa-search fa-2x"></i></a>
                <div id="mm" class="theme-navigate-menu-panel">
                    <div data-options="name:'all'">全部内容</div>
                    <div data-options="name:'customer'">客户</div>
                    <div data-options="name:'linker'">联系人</div>
                </div>
                <div class="theme-navigate-user-panel">
                    <dl>
                        <dd>
                            <img class="yk-img" src="${userinfo.uimage }" width="86"
                                 height="86"> <b class="badge-prompt">${userinfo.uname }</b>
<!--                                  <i class="badge color-important">10</i>  -->
                                                                                   电话： <span>${userinfo.phone }</span>
                            <p>
                                                                                      所属部门：<i class="text-success">${userinfo.getCrmDept().getCrmDname()}</i>
                            </p>
                        </dd>
                        <dt>
<!--                             <a class="theme-navigate-user-modify">修改资料</a> -->
                            <a id="yk-cancel-zhuxiao"
                               class="theme-navigate-user-logout">注销</a>
                        </dt>
                    </dl>
                </div>
            </div>

            <div id="yk-cancel-user" class="easyui-dialog"
                 data-options="title:'注销',width:200,height:150,closed:true,
		             resizable:true,modal:true,bodyCls:'by',buttons:'#yk-cancel-user-btn'">
                <div>您确定要退出吗？</div>
            </div>
            <div id="yk-cancel-user-btn">
                <a href="#" id="yk-cancel-user-btn-ave" class="easyui-linkbutton"
                   data-options="width:50">确定</a>
                <a href="#" id="yk-cancel-user-btn-close" class="easyui-linkbutton"
                   data-options="width:40">取消</a>
            </div>

            <div class="right">
                <div style="display: inline-block; margin-right: 10px;"
                     id="tp-weather-widget"></div>
                <a href="#" class="easyui-menubutton theme-navigate-user-button"
                   data-options="menu:'.theme-navigate-user-panel'">${userinfo.uname }</a>
                <a href="#" class="easyui-menubutton theme-navigate-more-button"
                   data-options="menu:'#more',hasDownArrow:false"></a>
                <div id="more" class="theme-navigate-more-panel">
                    <div>
                        <a id="prevent-us" class="top-l-btn" data-options="plain:true">参与改进计划</a>
                    </div>
                    <div>
                        <a id="link-us" class="top-l-btn" data-options="plain:true">联系我们</a>
                    </div>
                    <div>
                        <a id="update-us" class="top-l-btn" data-options="plain:true">检测更新</a>
                    </div>
                    <div>
                        <a id="about-us" class="top-l-btn" data-options="plain:true">关于</a>
                    </div>
                </div>

            </div>
        </div>

    </div>

    <!--开始左侧菜单-->
    <div
            data-options="region:'west',border:false,bodyCls:'theme-left-layout'"
            style="width: 200px;">


        <!--正常菜单-->
        <div class="theme-left-normal">
            <!--theme-left-switch 如果不需要缩进按钮，删除该对象即可-->
            <div class="left-control-switch theme-left-switch">
                <i class="fa fa-chevron-left fa-lg"></i>
            </div>

            <!--start class="easyui-layout"-->
            <div class="easyui-layout" data-options="border:false,fit:true">
                <!--start region:'north'-->
                <div data-options="region:'north',border:false"
                     style="height: 120px;">
                    <!--start theme-left-user-panel-->
                    <div class="theme-left-user-panel">
                        <dl>
                            <dt>
                                <img class="yk-img" src="${userinfo.uimage }" width="43"
                                     height="43">
                            </dt>
                            <dd>
                                <b class="badge-prompt">${userinfo.uname }</b>
<!--                                  <i class="badge color-important">10</i>  -->
                                                                                                  电话： <span>${userinfo.phone }</span>
                                <p>
                                                                                                所属部门：<i class="text-success">${userinfo.getCrmDept().getCrmDname()}</i>
                                </p>
                            </dd>

                        </dl>
                    </div>
                    <!--end theme-left-user-panel-->
                </div>
                <!--end region:'north'-->

                <!--start region:'center'-->
                <div data-options="region:'center',border:false">


                    <!--start easyui-accordion-->
                    <div class="easyui-accordion" data-options="border:false,fit:true">
                        <g:g id="24">
                        <div title="&nbsp;售前管理" data-options="iconCls:'icon-sale_befer'">
                            <ul class="easyui-datalist"
                                data-options="border:false,fit:true">
                                <g:g id="76">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'zjk-saleChance'">销售机会</a></li>
                                </g:g>
                                <g:g id="77">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'zjk-need'">客户需求</a></li>
                                       </g:g>
                                       <g:g id="78">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'zjk-scheme'">解决方案</a></li>
                                       </g:g>
                                       <g:g id="79">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'zjk-salePlan'">销售计划</a></li>
                                       </g:g>
                                       <g:g id="80">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'zjk-competitor'">竞争对手</a></li>
                                       </g:g>
                                       <g:g id="81">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'zjk-offer'">报价</a></li>
                                     </g:g>
                             </ul>
                        </div>
                        </g:g>
                        <g:g id="25">
                        <div title="&nbsp;售中管理" data-options="iconCls:'icon-saling'">
                            <ul class="easyui-datalist"
                                data-options="border:false,fit:true">
                                <g:g id="82">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/saling/contractList'">合同/订单</a></li>
                                       </g:g>
                                       <g:g id="83">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/toContractClientCodetailsVOList'">订单/合同明细</a>
                                       
                                </li>
                                </g:g>
                                <g:g id="84">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/togetDispatcherContractClientProductVOList'">发货明细</a>
                                </li>
                                </g:g>
                                <g:g id="85">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/toGetDispatcherContractClientUserInfoVOList'">发货单</a>
                                </li>
                                </g:g>

                                <!-- <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/toPlaningPayList'">付款计划</a></li>
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/toPayList'">付款记录</a></li>
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/toPlaningBackClientContractUserInfoVOList'">回款计划</a>
                                </li>
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/toBackClientContractUserInfoVOList'">回款记录</a>
                                </li> -->
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/toRefundContractClientList'">退款单</a></li>
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/saling/toRefundDetailProductVO'">退款记录</a></li>
                            </ul>
                        </div>
                        </g:g>
                        <g:g id="22">
                        <div title="&nbsp;财务管理" data-options="iconCls:'icon-saling'">
                            <ul class="easyui-datalist"
                                data-options="border:false,fit:true">
								<%-- <g:g id="86">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/toPlaningPayList'">付款计划</a></li>
                                       </g:g>
                                       <g:g id="87">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/toPayList'">付款记录</a></li>
                                       </g:g>--%>
                                       <g:g id="88"> 
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/toPlaningBackClientContractUserInfoVOList'">回款计划</a>
                                </li>
                                </g:g>
                                <g:g id="89">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/toBackClientContractUserInfoVOList'">回款记录</a>
                                </li>

                                </g:g>
                                <%-- <g:g id="90">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/toRefundContractClientList'">退款单</a></li>
                                </g:g>
                                <g:g id="91">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'/saling/toRefundDetailProductVO'">退款记录</a></li>
                                       </g:g> --%>

                            </ul>
                        </div>
                        </g:g>
                        <g:g id="27">
                        <div title="&nbsp;售后管理" data-options="iconCls:'icon-sale_after'">
                            <ul class="easyui-datalist"
                                data-options="border:false,fit:true">
                                <g:g id="92">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'after-sale-server'">客户服务</a></li>
                                        </g:g>
                                       <g:g id="93">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'complaint'">客户投诉</a></li>
                                        </g:g>
                                       <g:g id="94">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'client-care'">客户关怀</a></li>
                                        </g:g>
                            </ul>
                        </div>
                        </g:g>
                        <g:g id="28">
                        <div title="&nbsp;产品管理" data-options="iconCls:'icon-production'">
                            <ul class="easyui-datalist" data-options="border:false,fit:true">
                            <g:g id="95">
                                <li><a class="left-l-btn" data-options="plain:true,link:'repositoryM'">仓库管理</a></li>
                                </g:g>
                                <g:g id="96">
                                <li><a class="left-l-btn" data-options="plain:true,link:'pPurchaseM'">采购管理</a></li>
                                </g:g>
                                <g:g id="97">
                                <li><a class="left-l-btn" data-options="plain:true,link:'pPurchasergM'">采购退货管理</a></li>
                                </g:g>
                                <g:g id="98">
                                <li><a class="left-l-btn" data-options="plain:true,link:'pRepository'">产品库存管理</a></li>
                                </g:g>
                                <g:g id="99">
                                <li><a class="left-l-btn" data-options="plain:true,link:'pIOR'">产品出入库管理</a></li>
                                </g:g>
                                <g:g id="100">
                                <li><a class="left-l-btn" data-options="plain:true,link:'pDetils'">产品明细管理</a></li>
                                </g:g>
                                <g:g id="101">
                                <li><a class="left-l-btn" data-options="plain:true,link:'pCategory'">产品分类管理</a></li>
                                </g:g>
                            </ul>
                        </div>
                        </g:g>
                        <g:g id="29">
                        <div title="&nbsp;客户管理" data-options="iconCls:'icon-customer'">
                            <ul class="easyui-datalist"
                                data-options="border:false,fit:true">
                                <g:g id="102">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'to-client'">客户管理</a></li>
                                       </g:g>
                                       <g:g id="103">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'to-contact'">联系人管理</a></li>
                                       </g:g>
                                       <g:g id="104">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'to-client-transfer-details'">客户转移日志</a></li>
                                       </g:g>
                                       <g:g id="105">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'to-client-memorial'">纪念日</a></li>

                                <!-- <li><a class="left-l-btn"
                                       data-options="plain:true,link:''">工具</a></li> -->

                                       </g:g>
<%--                                        <g:g id="106"> --%>
<!--                                 <li><a class="left-l-btn" -->
<!--                                        data-options="plain:true,link:''">工具</a></li> -->
<%--                                        </g:g> --%>

                            </ul>
                        </div>
                        </g:g>
                        <g:g id="30">
                        <div title="&nbsp;权限管理" data-options="iconCls:'icon-rate'">
                            <ul class="easyui-datalist"
                                data-options="border:false,fit:true">
                                <!-- 										<li><a class="left-l-btn" -->
                                <!-- 											data-options="plain:true,link:''">登录管理</a></li> -->
                                <!-- 										<li><a class="left-l-btn" -->
                                <!-- 											data-options="plain:true,link:''">超级管理员</a></li> -->
                                <g:g id="33">
                                    <li><a class="left-l-btn"
                                           data-options="plain:true,link:'crmdept'">部门管理</a></li>
                                </g:g>
                                <g:g id="34">
                                    <li><a class="left-l-btn"
                                           data-options="plain:true,link:'userinfo'">用户管理</a></li>
                                </g:g>
                                <g:g id="35">
                                    <li><a class="left-l-btn"
                                           data-options="plain:true,link:'roletable'">角色管理</a></li>
                                </g:g>
                                <g:g id="36">
                                    <li><a class="left-l-btn"
                                           data-options="plain:true,link:'menubartable'">功能管理</a></li>
                                </g:g>
                            </ul>
                        </div>
                        </g:g>
                        <div title="&nbsp;个人设置" data-options="iconCls:'icon-per'">

                            <ul class="easyui-datalist" data-options="border:false,fit:true">
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'updateUserself'">修改个人信息</a></li>
                                <li><a class="left-l-btn"
                                       data-options="plain:true,link:'uphead'">上传头像</a></li>
                            </ul>
                        </div>

                    </div>
                    <!--end easyui-accordion-->

                </div>
                <!--end region:'center'-->
            </div>
            <!--end class="easyui-layout"-->

        </div>
        <!--最小化菜单-->
        <div class="theme-left-minimal">
            <ul class="easyui-datalist" data-options="border:false,fit:true">
                <li><a title="点击切换主题" class="skin"
                       style="background-color: transparent; border: 0px;" href="#"><i
                        class="fa fa-home fa-2x" style="background-color: white;"></i>
                    <p style="color: #fff; font-weight: bold;">主题</p></a></li>
                <li><i class="fa fa-book fa-2x"></i>
                    <p>组件</p></li>
                <li><i class="fa fa-pencil fa-2x"></i>
                    <p>编辑</p></li>
                <li><i class="fa fa-cog fa-2x"></i>
                    <p>设置</p></li>
                <li><a class="left-control-switch"><i
                        class="fa fa-chevron-right fa-2x"></i>
                    <p>打开</p></a></li>
            </ul>
        </div>

    </div>
    <!--结束左侧菜单-->
    <%--,href:'info.html'--%>
    <div data-options="region:'center',border:false" id="control"
         style="padding: 0px; background: #fff;">
        <div class="easyui-layout" data-options="border:false,fit:true">
            <%--<div data-options="region:'north'" style="background: #0c80d7;height:6%;min-height: 30px;">--%>

            <%--</div>--%>
            <div data-options="region:'center'" style="min-height: 600px;">
                <div id="home-tabs"
                     class="easyui-tabs theme-tab-red-line theme-tab-body-unborder"
                     data-options="fit:true, border:false,tools:'#home-tabs-tools',justified:false">
                    <div title="首页" style="padding: 0px; display: none;">
                        <div class="easyui-layout" data-options="border:false,fit:true">
                            <div data-options="border:false,region:'north'" style="height: 10%;text-align: center;">
                                <div style="margin: 10px 50px;">
                                	<select id="groupClientWhere" class="easyui-combobox" name="dept"
										style="width: 40%;" data-option="width:80%">
											<option value="type">客户类型分布统计</option>
											<option value="stage">客户阶段分布统计</option>
											<option value="relationship">客户关系分布统计</option>
											<option value="source">客户来源分布</option>
											<option value="scale">客户人员规模分布</option>
											<option value="industry">客户人员行业分布</option>
									</select>
                                </div>
                            </div>
                            <div data-options="border:false,region:'center'" style="text-align: center;"
                                 >
                                <div id="main" style="width: 40%; height: 300px;float: left;margin-right: 5%;"></div>
                                <div id="main1" style="width: 40%; height: 300px;float: left;margin-right: 5%;"></div>
                                <div id="main2" style="width: 40%; height: 300px;float: left;margin-right: 5%;"></div>
                                <div id="main3" style="width: 40%; height: 300px;float: left;margin-right: 5%;"></div>
                            </div>
                            <!-- <div data-options="region:'south'" style="height: 120px;">
                                <div>
                                    <h3>&nbsp;小工具</h3>
                                </div>
                                <a href="#" id="center-l-btn-1" class="easyui-linkbutton"
                                   data-options="height:110,width:250"><i
                                        class="fa fa-calculator fa-5x"></i>计算器</a>
                            </div> -->
                        </div>
                    </div>
                </div>
                <div id="home-tabs-tools">
                    <a id="close-now" href="#" class="easyui-linkbutton" plain="true"
                       iconCls="icon-remove"></a> <a id="close-all" href="#"
                                                     class="easyui-linkbutton" plain="true" iconCls="icon-clear"></a>
                </div>
            </div>
            <!-- 底部固定内容 -->
            <%--<div data-options="region:'south'" style="height:13%;min-height:70px;overflow: hidden;">--%>

            <%--</div>--%>
            <!-- 固定内容结束 -->
        </div>
    </div>
</div>


<script>
    $(function () {

        /*布局部分*/
        $('#master-layout').layout({
            fit: true
            /*布局框架全屏*/
        });

        /*左侧菜单控制部分*/

        var left_control_status = true;
        var left_control_panel = $("#master-layout")
            .layout("panel", 'west');

        $(".left-control-switch").on("click", function () {
            if (left_control_status) {
                left_control_panel.panel('resize', {
                    width: 70
                });
                left_control_status = false;
                $(".theme-left-normal").hide();
                $(".theme-left-minimal").show();
            } else {
                left_control_panel.panel('resize', {
                    width: 200
                });
                left_control_status = true;
                $(".theme-left-normal").show();
                $(".theme-left-minimal").hide();
            }
            $("#master-layout").layout('resize', {
                width: '100%'
            })
        });

        /*左侧菜单控制结束*/

        /*
         * 修改个人信息
         */
        $(".theme-navigate-user-modify").on("click", function () {
            $('.theme-navigate-user-panel').menu('hide');
            $.insdep.window({
                id: "personal-set-window",
                href: "user.html",
                title: "修改资料"
            });

        });
        //$.insdep.control("list.html");
    });

    function doSearch(value, name) {
        alert('You input: ' + value + '(' + name + ')');
    }
</script>

<!--第三方插件加载-->
<!--天气插件-->
<script>
    (function (T, h, i, n, k, P, a, g, e) {
        g = function () {
            P = h.createElement(i);
            a = h.getElementsByTagName(i)[0];
            P.src = k;
            P.charset = "utf-8";
            P.async = 1;
            a.parentNode.insertBefore(P, a)
        };
        T["ThinkPageWeatherWidgetObject"] = n;
        T[n] || (T[n] = function () {
            (T[n].q = T[n].q || []).push(arguments)
        });
        T[n].l = +new Date();
        if (T.attachEvent) {
            T.attachEvent("onload", g)
        } else {
            T.addEventListener("load", g, false)
        }
    }(window, document, "script", "tpwidget",
        "//widget.seniverse.com/widget/chameleon.js"))
</script>
<script>
    tpwidget("init", {
        "flavor": "slim",
        "location": "WX4FBXXFKE4F",
        "geolocation": "enabled",
        "language": "zh-chs",
        "unit": "c",
        "theme": "chameleon",
        "container": "tp-weather-widget",
        "bubble": "enabled",
        "alarmType": "badge",
        "color": "#00AFDB",
        "uid": "U7F6DAB96E",
        "hash": "a3cae15f72991c08867b2c66e3bd9f3a"
    });
    tpwidget("show");
</script>
<!--第三方插件加载结束-->

</body>
</html>

